MessageHandler<T>
Processes all messages in a Normal and Priority Queue. Expects to be called in 1 thread. i.e. Non Thread-Safe.
Assembly: ServiceStack.dll
View Source
Declaration
public class MessageHandler<T> : IMessageHandler, IDisposable
Properties
ReplyClientFactory
View Source
Declaration
public Func<string, IOneWayClient> ReplyClientFactory { get; set; }
PublishResponsesWhitelist
View Source
Declaration
public string[] PublishResponsesWhitelist { get; set; }
PublishToOutqWhitelist
View Source
Declaration
public string[] PublishToOutqWhitelist { get; set; }
TotalMessagesProcessed
View Source
Declaration
public int TotalMessagesProcessed { get; }
TotalMessagesFailed
View Source
Declaration
public int TotalMessagesFailed { get; }
TotalRetries
View Source
Declaration
public int TotalRetries { get; }
TotalNormalMessagesReceived
View Source
Declaration
public int TotalNormalMessagesReceived { get; }
TotalPriorityMessagesReceived
View Source
Declaration
public int TotalPriorityMessagesReceived { get; }
TotalOutMessagesReceived
View Source
Declaration
public int TotalOutMessagesReceived { get; }
LastMessageProcessed
View Source
Declaration
public DateTime? LastMessageProcessed { get; }
ProcessQueueNames
View Source
Declaration
public string[] ProcessQueueNames { get; set; }
MqClient
View Source
Declaration
public IMessageQueueClient MqClient { get; }
MessageType
View Source
Declaration
public Type MessageType { get; }
Fields
DefaultRetryCount
View Source
Declaration
public const int DefaultRetryCount = 2
Methods
Process(IMessageQueueClient)
View Source
Declaration
public void Process(IMessageQueueClient mqClient)
Parameters
Type | Name |
---|---|
ServiceStack.Messaging.IMessageQueueClient | mqClient |
ProcessQueue(IMessageQueueClient, String, Func<Boolean>)
View Source
Declaration
public int ProcessQueue(IMessageQueueClient mqClient, string queueName, Func<bool> doNext = null)
Returns
System.Int32
Parameters
Type | Name |
---|---|
ServiceStack.Messaging.IMessageQueueClient | mqClient |
System.String | queueName |
System.Func<System.Boolean> | doNext |
GetStats()
View Source
Declaration
public IMessageHandlerStats GetStats()
Returns
ServiceStack.Messaging.IMessageHandlerStats
ProcessMessage(IMessageQueueClient, Object)
View Source
Declaration
public void ProcessMessage(IMessageQueueClient mqClient, object mqResponse)
Parameters
Type | Name |
---|---|
ServiceStack.Messaging.IMessageQueueClient | mqClient |
System.Object | mqResponse |
ProcessMessage(IMessageQueueClient, IMessage<T>)
View Source
Declaration
public void ProcessMessage(IMessageQueueClient mqClient, IMessage<T> message)
Parameters
Type | Name |
---|---|
ServiceStack.Messaging.IMessageQueueClient | mqClient |
ServiceStack.Messaging.IMessage<T> | message |
Dispose()
View Source
Declaration
public void Dispose()
Implements
- ServiceStack.Messaging.IMessageHandler
System.IDisposable